<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8">
		<title>Button Click Limit</title>
		<script>
			window.onload  = function() {
				var clickCount = 0;
				var button = document.getElementById('sync-button');

				button.addEventListener('click', function() {
					clickCount++;
					if (clickCount >= 3) {
						  button.disabled = true;
						alert('按钮已被禁用，您已点击了三次。');
					} else {
						alert('点击次数：' + clickCount);
					}
				});
			};
		</script>
	</head>
	<body>
		<button id="sync-button">同步数据</button>
	</body>
</html>
